/*
 * @Descripttion: 后台管理系统
 * @version: 1.0
 * @Author: 狸猫
 * @Date: 2023-11-27 15:56:18
 * @LastEditors: 狸猫
 * @LastEditTime: 2024-03-08 10:25:53
 */
import request from "@/utils/request";

//成员列表
export function communityHouseUserList(houseId) {
  return request({
    url: "/enterprise/houseUser/houseUser/list?houseId=" + houseId,
    method: "get",
  });
}

// 删除成员
export function delMember(id) {
  return request({
    url: "/enterprise/houseUser/houseUser/" + id,
    method: "delete",
  });
}

// 修改预定时间
export function updateReservationInfo(data) {
  return request({
    url: "/enterprise/order/order/updateReservationInfo",
    method: "post",
    data: data,
  });
}

// 查询房间详情
export function getOrder(orderId) {
  return request({
    url: "/enterprise/order/order/" + orderId,
    method: "get",
  });
}

// 新增成员
export function addMember(data) {
  return request({
    url: "/enterprise/house/member",
    method: "post",
    data: data ,
  });
}

// 编辑成员
export function editMember(data) {
  return request({
    url: "/enterprise/houseUser/houseUser",
    method: "put",
    data: { communityHouseUserList: data },
  });
}
